package com.will.client.adapter;

import io.netty.channel.ChannelHandlerContext;
import io.netty.channel.ChannelInboundHandlerAdapter;
import io.netty.util.ReferenceCountUtil;

/**
 * @author 杨明智
 * @version:1.0
 * @create 2019年01月13日 12:21 AM
 * @description 业务处理通道
 **/
public class CustomChannelHandlerAdapter extends ChannelInboundHandlerAdapter {

    @Override
    public void channelRead(ChannelHandlerContext ctx, Object msg) throws Exception {
        String message = (String) msg;
        System.out.println(message);
        ReferenceCountUtil.release(msg);
    }
}
